package com.example.rentsystem.entity;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;

import java.text.SimpleDateFormat;
import java.util.Date;

@Data
@AllArgsConstructor
@Builder
public class Advice {

    private int id;
    private String content;
    private Date time;

    public String getTime() {
        return new SimpleDateFormat("yyyy.MM.dd").format(time);
    }
}
